﻿using MassTransit;
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;

namespace Finbook.Entity.Cmds
{
    public class TestRequestHandler
        : IConsumer<TestRequest>
    {
        public async Task Consume(ConsumeContext<TestRequest> context)
        {
            Console.WriteLine($"//*******{DateTime.Now.ToString("")}{context.Message.Name}");
            await context.RespondAsync(new TestResponse() { Id=context.Message.Id, Name=context.Message.Name });
        }
    }
}
